home *** CD-ROM | disk | FTP | other *** search
/ Turnbull China Bikeride / Turnbull China Bikeride - Disc 2.iso / ACORNUSERS / CBSA / EDUCATION / SAVER / h / EventData next >
Text File  |  1997-12-15  |  1KB  |  113 lines

  1.  
  2. //-----------------------------------
  3. //             EventData.h
  4. //-----------------------------------
  5.  
  6.  
  7. #ifndef EventData_H
  8. #define EventData_H
  9.  
  10. enum bool {FALSE,TRUE};
  11.  
  12. struct Message_Info
  13. {
  14.   int size;
  15.   int task_sender;
  16.   int my_ref;
  17.   int your_ref;
  18.   int code;
  19.   union
  20.   {
  21.     int data[123];
  22.     struct
  23.     {
  24.       int dest_window;
  25.       int icon;
  26.       int x;
  27.       int y;
  28.       int size;
  29.       int type;
  30.       char pathname[468];
  31.     } data_load_ack;
  32.   };
  33. };
  34.  
  35. struct Box
  36. {
  37.   int xmin;
  38.   int ymin;
  39.   int xmax;
  40.   int ymax;
  41. };
  42.  
  43. struct Window_Info
  44. {
  45.   int handle;
  46.   int xmin;
  47.   int ymin;
  48.   int xmax;
  49.   int ymax;
  50.   int scrollx;
  51.   int scrolly;
  52.   union
  53.   {
  54.      struct
  55.      {
  56.        int window_behind;
  57.        int scrolldx;
  58.        int scrolldy;
  59.      } win;
  60.      struct
  61.      {
  62.        Xmin;
  63.        Ymin;
  64.        Xmax;
  65.        Ymax;
  66.      } box;
  67.   };
  68. };
  69.  
  70. struct Mouse_Info
  71. {
  72.   int x;
  73.   int y;
  74.   int buttons;
  75.   int window;
  76.   int icon;
  77. };
  78.  
  79. struct Key_Info
  80. {
  81.   int window;
  82.   int icon;
  83.   int xoffset;
  84.   int yoffset;
  85.   int caret_flag;
  86.   int caret_index;
  87.   int code;
  88. };
  89.  
  90. struct Menu_Info
  91. {
  92.   int item[128];
  93. };
  94.  
  95. union EventData
  96. {
  97.   Window_Info Window_Request;
  98.   Mouse_Info Mouse_Click;
  99.   Box Drag_Box;
  100.   Key_Info Key_Pressed;
  101.   Menu_Info Menu_Selection;
  102.   
  103.   struct
  104.   {
  105.     int address;
  106.     int contents;
  107.   } Non_Zero;
  108.   
  109.   Message_Info User_Message;
  110. };
  111.  
  112. #endif
  113.